package org.demo.patten.interpreter;

/**
 * @author zhuj
 * @date 2025/3/29
 * @apiNote
 */
public class SubtractExpression implements Expression{
    private final Expression left, right;
    public SubtractExpression(Expression left, Expression right) {
        this.left = left;
        this.right = right;
    }
    @Override
    public int interpret() {
        return left.interpret() - right.interpret();
    }
}
